<?php
	require_once('../inc/fen_fns.php');
	
	sec_session_start();
	$pid = substr($_GET['pid'],1);
	
	$query = $_DB->Query("SELECT
							fen_toplanti.id as toplanti_id,
							fen_toplanti.member_id as toplanti_member_id,
							date_FORMAT(fen_toplanti.basvuru_tarihi, '%d/%m/%Y') as basvuru_tarihi,	
							fen_toplanti.toplanti_adi,
							fen_toplanti.ulke,
							fen_toplanti.sehir,	
							date_FORMAT(fen_toplanti.tarih1, '%d/%m/%Y') as tarih1,		
							date_FORMAT(fen_toplanti.tarih2, '%d/%m/%Y') as tarih2,
							fen_toplanti.bildiri_konusu,
							fen_toplanti.baska_destek,
							fen_toplanti.baska_destek1,
							fen_toplanti.baska_destek2,
							fen_toplanti.baska_destek3,
							fen_toplanti.baska_destek_diger,
							fen_toplanti.talep_sebebi1,
							fen_toplanti.talep_sebebi2,
							fen_toplanti.talep_sebebi3,
							fen_toplanti.destek_turu,
							fen_toplanti.tutar,
							fen_toplanti.para_birimi,
							fen_toplanti.ders_durumu,
							fen_toplanti.telafi_ders_adi,
							fen_toplanti.telafi_kim,
							fen_toplanti.telafi_sinif,
							fen_toplanti.telafi_tarih,
							fen_toplanti.telafi_hoca,
							fen_members.name,
							fen_members.surname,
							fen_members.titr,
							fen_faculty.faculty_name,
							fen_department.department_name											
							from fen_toplanti, fen_members, fen_faculty, fen_department
							WHERE
							fen_toplanti.member_id = fen_members.id and
							fen_toplanti.id = '$pid' and
							fen_members.username = '".$_SESSION['username']."'
							and fen_members.faculty_id = fen_faculty.id
							and fen_members.department_id = fen_department.id
							");
		$count = $_DB->GetResultNumber($query);
		
		$basvuru_tarihi = $_DB->GetResultValue($query, "0", "basvuru_tarihi");
		$toplanti_id = $_DB->GetResultValue($query, "0", "toplanti_id");
		$member_id = $_DB->GetResultValue($query, "0", "toplanti_member_id");
		$toplanti_adi = $_DB->GetResultValue($query, "0", "toplanti_adi");
		$ulke = $_DB->GetResultValue($query, "0", "ulke");
		$sehir = $_DB->GetResultValue($query, "0", "sehir");
		$tarih1 = $_DB->GetResultValue($query, "0", "tarih1");
		$tarih2 = $_DB->GetResultValue($query, "0", "tarih2");
		$bildiri_konusu = $_DB->GetResultValue($query, "0", "bildiri_konusu");
		$baska_destek = $_DB->GetResultValue($query, "0", "baska_destek");
		$baska_destek1 = $_DB->GetResultValue($query, "0", "baska_destek1");
		$baska_destek2 = $_DB->GetResultValue($query, "0", "baska_destek2");
		$baska_destek3 = $_DB->GetResultValue($query, "0", "baska_destek3");
		$baska_destek_diger = $_DB->GetResultValue($query, "0", "baska_destek_diger");
		$talep_sebebi1 = $_DB->GetResultValue($query, "0", "talep_sebebi1");
		$talep_sebebi2 = $_DB->GetResultValue($query, "0", "talep_sebebi2");
		$talep_sebebi3 = $_DB->GetResultValue($query, "0", "talep_sebebi3");
		$destek_turu = $_DB->GetResultValue($query, "0", "destek_turu");
		$tutar = $_DB->GetResultValue($query, "0", "tutar");
		$para_birimi = $_DB->GetResultValue($query, "0", "para_birimi");
		$ders_durumu = $_DB->GetResultValue($query, "0", "ders_durumu");
		
		$telafi_ders_adi = unserialize($_DB->GetResultValue($query, "0", "telafi_ders_adi"));
		$telafi_kim = unserialize($_DB->GetResultValue($query, "0", "telafi_kim"));
		$telafi_sinif = unserialize($_DB->GetResultValue($query, "0", "telafi_sinif"));
		$telafi_tarih = unserialize($_DB->GetResultValue($query, "0", "telafi_tarih"));
		$telafi_hoca = unserialize($_DB->GetResultValue($query, "0", "telafi_hoca"));
		
		
		$telafi_cizgi = array();
		if ($telafi_kim[0] == 'Kendim') { $telafi_cizgi[0] = "-";  } else { $telafi_cizgi[0] = ""; }
		if ($telafi_kim[1] == 'Kendim') { $telafi_cizgi[1] = "-";  } else { $telafi_cizgi[1] = ""; }
		if ($telafi_kim[2] == 'Kendim') { $telafi_cizgi[2] = "-";  } else { $telafi_cizgi[2] = ""; }
		if ($telafi_kim[3] == 'Kendim') { $telafi_cizgi[3] = "-";  } else { $telafi_cizgi[3] = ""; }


		$titr = $_DB->GetResultValue($query, "0", "titr");
		$name = $_DB->GetResultValue($query, "0", "name");
		$surname = $_DB->GetResultValue($query, "0", "surname");
		$faculty_name = $_DB->GetResultValue($query, "0", "faculty_name");
		$department_name = $_DB->GetResultValue($query, "0", "department_name");
		
		if ($baska_destek == '1') { $baska_destek_evet = "X"; } else { $baska_destek_hayir = "X"; }
		if ($baska_destek1 == '1') { $baska_destek1_evet = "X"; } 
		if ($baska_destek2 == '1') { $baska_destek2_evet = "X"; } 
		if ($baska_destek3 == '1') { $baska_destek3_evet = "X"; }
		if (strlen($baska_destek_diger) > '0') { $baska_destek_diger_evet = "X"; }
		if ($talep_sebebi1 == '1') { $talep_sebebi1_evet = "X"; }
		if ($talep_sebebi2 == '1') { $talep_sebebi2_evet = "X"; }
		if ($talep_sebebi3 == '1') { $talep_sebebi3_evet = "X"; }
		if ($destek_turu == 'Tam Destek') {
			if ($para_birimi == 'TL') {
				$tam_destek = $tutar." TL";
				$kismi_destek = "-";
			} else {
				$tam_destek = $tutar." $";
				$kismi_destek = "-";
			}
		} else if ($destek_turu == 'Kısmi Destek') {
			if ($para_birimi == 'TL') {
				$kismi_destek = $tutar." TL";
				$tam_destek = "-";
			} else {
				$kismi_destek = $tutar." $";
				$tam_destek = "-";
			}
		}
		
		if ($ders_durumu == 'Hayır') { $ders_durumu_hayir = "X"; $telafi_ders_adi = ""; $telafi_kim = ""; $telafi_sinif = ""; $telafi_tarih = ""; $telafi_hoca = ""; }
		
		$queryforcount = $_DB->Query("SELECT fen_toplanti.id from fen_toplanti, fen_members
				WHERE fen_toplanti.member_id = fen_members.id and
				fen_members.username = '".$_SESSION['username']."'");
		$querycount = $_DB->GetResultNumber($queryforcount);
				
		$query2 = $_DB->Query("SELECT date_FORMAT(fen_toplanti.tarih1, '%d/%m/%Y') as tarih1, ulke, sehir, destek_turu
				from fen_toplanti, fen_members
				WHERE fen_toplanti.member_id = fen_members.id and
				fen_members.username = '".$_SESSION['username']."' order by fen_toplanti.tarih1 DESC LIMIT 1,1");

		$son_parasal_destek_1_tarih = $_DB->GetResultValue($query2, "0", "tarih1");
		$son_parasal_destek_1_ulke = $_DB->GetResultValue($query2, "0", "ulke");
		$son_parasal_destek_1_sehir = $_DB->GetResultValue($query2, "0", "sehir"). " / ";
		
		if ($querycount > 1) {
			if ($_DB->GetResultValue($query2, "0", "destek_turu") == 'Tam Destek') { $son_parasal_destek_1_tam_destek_evet = "X"; } else { $son_parasal_destek_1_kismi_destek_evet = "X"; }
		}
		

		$query3 = $_DB->Query("SELECT date_FORMAT(fen_toplanti.tarih1, '%d/%m/%Y') as tarih1, ulke, sehir, destek_turu
				from fen_toplanti, fen_members
				WHERE
				fen_toplanti.member_id = fen_members.id and
				fen_members.username = '".$_SESSION['username']."' order by fen_toplanti.tarih1 DESC LIMIT 2,1");
		

		$son_parasal_destek_2_tarih = $_DB->GetResultValue($query3, "0", "tarih1");
		$son_parasal_destek_2_ulke = $_DB->GetResultValue($query3, "0", "ulke");
		$son_parasal_destek_2_sehir = $_DB->GetResultValue($query3, "0", "sehir"). " / ";
		if ($querycount > 2) {
		if ($_DB->GetResultValue($query3, "0", "destek_turu") == 'Tam Destek') { $son_parasal_destek_2_tam_destek_evet = "X"; } else { $son_parasal_destek_2_kismi_destek_evet = "X"; }
		}
		
		//if (login_check($mysqli, '>', '10') == true) {
		
//============================================================+
// File name   : example_002.php
// Begin       : 2008-03-04
// Last Update : 2010-08-08
//
// Description : Example 002 for TCPDF class
//               Removing Header and Footer
//
// Author: Nicola Asuni
//
// (c) Copyright:
//               Nicola Asuni
//               Tecnick.com LTD
//               Manor Coach House, Church Hill
//               Aldershot, Hants, GU12 4RQ
//               UK
//               www.tecnick.com
//               info@tecnick.com
//============================================================+

/**
 * Creates an example PDF TEST document using TCPDF
 * @package com.tecnick.tcpdf
 * @abstract TCPDF - Example: Removing Header and Footer
 * @author Nicola Asuni
 * @since 2008-03-04
 */

require_once('../config/lang/eng.php');
require_once('../tcpdf.php');

class MYPDF extends TCPDF {
	
	public function MultiRow($left, $right) {
		// MultiCell($w, $h, $txt, $border=0, $align='J', $fill=0, $ln=1, $x='', $y='', $reseth=true, $stretch=0)
	
		$page_start = $this->getPage();
		$y_start = $this->GetY();
	
		// write the left cell
		$this->MultiCell(40, 0, $left, 1, 'R', 1, 2, '', '', true, 0);
	
		$page_end_1 = $this->getPage();
		$y_end_1 = $this->GetY();
	
		$this->setPage($page_start);
	
		// write the right cell
		$this->MultiCell(0, 0, $right, 1, 'J', 0, 1, $this->GetX() ,$y_start, true, 0);
	
		$page_end_2 = $this->getPage();
		$y_end_2 = $this->GetY();
	
		// set the new row position by case
		if (max($page_end_1,$page_end_2) == $page_start) {
			$ynew = max($y_end_1, $y_end_2);
		} elseif ($page_end_1 == $page_end_2) {
			$ynew = max($y_end_1, $y_end_2);
		} elseif ($page_end_1 > $page_end_2) {
			$ynew = $y_end_1;
		} else {
			$ynew = $y_end_2;
		}
	
		$this->setPage(max($page_end_1,$page_end_2));
		$this->SetXY($this->GetX(),$ynew);
	}

}

// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);

// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Onur Mendi');
$pdf->SetTitle('BAHÇEŞEHİR ÜNİVERSİTESİ');
$pdf->SetSubject('Yurtiçi ve Yurtdışı Bilimsel Toplantılara Katılım İstek Formu');
$pdf->SetKeywords('Created by Onur Mendi onur@mendi.co');

// remove default header/footer
$pdf->setPrintHeader(false);
$pdf->setPrintFooter(false);

// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);

//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, '9', PDF_MARGIN_RIGHT);

//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);

//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);

//set some language-dependent strings
$pdf->setLanguageArray($l);

// ---------------------------------------------------------

// set font
$pdf->SetFont('dejavusans', 'B', 9);

// add a page
$pdf->AddPage();

// set some text to print
$txt = <<<EOD
BAHÇEŞEHİR ÜNİVERSİTESİ
Araştırma ve Yayın Faaliyetleri Koordinatörlüğü
Yurtiçi ve Yurtdışı Bilimsel Toplantılara Katılım İstek Formu
EOD;

// print a block of text using Write()
$pdf->Write($h=5, $txt, $link='', $fill=0, $align='C', $ln=true, $stretch=0, $firstline=false, $firstblock=false, $maxh=0);
$pdf->SetFont('dejavusans', 'R', 9);

$date = date("d.m.Y");
$dateyear = date("Y");

if ($ders_durumu != 'Hayır') { 
	$ders_durumu_tablo = <<<EOD
<tr STYLE="line-height:100%">
<td width="33%">$telafi_ders_adi[2]</td>
<td width="33%">$telafi_tarih[2] $telafi_cizgi[2] $telafi_sinif[2]</td>
<td width="34%">$telafi_hoca[2]</td>
</tr>
<tr STYLE="line-height:100%">
<td width="33%">$telafi_ders_adi[3]</td>
<td width="33%">$telafi_tarih[3] $telafi_cizgi[3] $telafi_sinif[3]</td>
<td width="34%">$telafi_hoca[3]</td>
</tr>	
EOD;
} else {
	$ders_durumu_tablo = "";
}




$tbl = <<<EOD
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="3" border="1">
    <tr>
        <td align="center" bgcolor="#f0f0f0">I. KİŞİSEL BİLGİLER</td>
    </tr>
    <tr>
        <td width="25%">Adı ve Soyadı, Unvanı:</td>
        <td width="75%">$titr $name $surname $count2</td>
    </tr>
    <tr>
       <td width="25%">Fakülte ve Bölümü:</td>
       <td width="75%">$faculty_name / $department_name</td>
    </tr>
</table>
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="3" border="1">
    <tr>
        <td align="center" bgcolor="#f0f0f0">II. BİLİMSEL TOPLANTI İLE İLGİLİ BİLGİLER</td>
    </tr>
    <tr>
        <td width="25%">Toplantının Adı:</td>
        <td width="75%">$toplanti_adi</td>
    </tr>
    <tr>
       <td width="25%">Şehir ve Ülke:</td>
       <td width="75%">$sehir / $ulke</td>
    </tr>
    <tr>
        <td width="25%">Toplantı Tarihi:</td>
        <td width="75%">$tarih1 - $tarih2</td>
    </tr>
    <tr>
        <td width="25%">Bildiri Konusu:</td>
        <td width="75%">$bildiri_konusu</td>
    </tr>
</table>
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="3" border="1">
    <tr>
        <td align="center" bgcolor="#f0f0f0">III. SEYAHAT GİDERLERİNİN KARŞILANMASINA İLİŞKİN BİLGİLER</td>
    </tr>
    <tr>
        <td>Bu seyahat için başka kaynaklardan destek alıyor musunuz?:  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [&nbsp;<b>$baska_destek_evet</b> ] Evet  &nbsp;&nbsp;&nbsp; [&nbsp;<b>$baska_destek_hayir</b> ] Hayır</td>
    </tr>
    <tr>
       <td width="25%">Evet ise, hangileri<br>karşılanmaktadır?:</td>
       <td width="75%">  [&nbsp;<b>$baska_destek1_evet</b> ] Yol  &nbsp;&nbsp;&nbsp; [&nbsp;<b>$baska_destek2_evet</b> ] Kayıt  &nbsp;&nbsp;&nbsp; [&nbsp;<b>$baska_destek3_evet</b> ] Konaklama ve Yemek<br>  [&nbsp;<b>$baska_destek_diger_evet</b> ] Diğer: $baska_destek_diger</td>
    </tr>
</table>
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="3" border="1">
    <tr>
        <td align="center" bgcolor="#f0f0f0">IV. ÜNİVERSİTEDEN ALINAN EN SON PARASAL DESTEKLER</td>
    </tr>
    <tr>
        <td width="25%">1. Tarih: $son_parasal_destek_1_tarih</td>
        <td width="38%"> Yer: $son_parasal_destek_1_sehir $son_parasal_destek_1_ulke</td>
        <td width="37%"> [&nbsp;<b>$son_parasal_destek_1_tam_destek_evet</b> ] Tam Destek  &nbsp; [&nbsp;<b>$son_parasal_destek_1_kismi_destek_evet</b> ] Kısmi Destek</td>
    </tr>
    <tr>
       <td width="25%">2. Tarih: $son_parasal_destek_2_tarih</td>
       <td width="38%"> Yer: $son_parasal_destek_2_sehir $son_parasal_destek_2_ulke</td>
        <td width="37%"> [&nbsp;<b>$son_parasal_destek_2_tam_destek_evet</b> ] Tam Destek  &nbsp; [&nbsp;<b>$son_parasal_destek_2_kismi_destek_evet</b> ] Kısmi Destek</td>
    </tr>
</table>
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="3" border="1">
    <tr>
        <td align="center" bgcolor="#f0f0f0">V. TALEP EDİLEN PARASAL DESTEKLE İLGİLİ BİLGİLER</td>
    </tr>
    <tr>
        <td align="center">[&nbsp;<b>$talep_sebebi1_evet</b> ] Yol  &nbsp;&nbsp;&nbsp; [&nbsp;<b>$talep_sebebi2_evet</b> ] Kayıt  &nbsp;&nbsp;&nbsp; [&nbsp;<b>$talep_sebebi3_evet</b> ] Harcırah</td>
    </tr>
    <tr>
       <td width="25%">İstenen destek tutarı:</td>
       <td width="38%" align="center">Tam Destek<br>$tam_destek</td>
       <td width="37%" align="center">Kısmi Destek<br>$kismi_destek</td>
    </tr>
</table>
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="3" border="1">
    <tr>
        <td> [&nbsp;<b>$ders_durumu_hayir</b> ] Belirtilen süre içinde dersim yoktur.</td>
    </tr>
    <tr bgcolor="#f0f0f0">
        <td width="33%">Belirtilen süre içinde sorumlu olduğum dersler:</td>
        <td width="33%">Aşağıdaki tarihlerde tarafımdan ilave dersler yapılacaktır.</td>
        <td width="34%">Dersler aşağıdaki öğretim üyeleri tarafından telafi edilecektir.</td>
    </tr>
    <tr STYLE="line-height:100%">
        <td width="33%">$telafi_ders_adi[0]</td>
        <td width="33%">$telafi_tarih[0] $telafi_cizgi[0] $telafi_sinif[0]</td>
        <td width="34%">$telafi_hoca[0]</td>
    </tr>
    <tr STYLE="line-height:100%">
        <td width="33%">$telafi_ders_adi[1]</td>
        <td width="33%">$telafi_tarih[1] $telafi_cizgi[1] $telafi_sinif[1]</td>
        <td width="34%">$telafi_hoca[1]</td>
    </tr>
    $ders_durumu_tablo
</table>
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="7" border="1">
    <tr>
        <td width="66%">Yukarıda ayrıntıları belirtilen kısa süreli yurt içi/dışı<br>toplantıya katılabilmem için gereğini bilgi ve onayınıza sunarım.<br><br><br>Tarih: $basvuru_tarihi &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; İmza:</td>
        <td width="34%">Bölüm Başkanı:<br><br><br><br>Tarih: .... / .... / $dateyear     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(İmza)</td>
    </tr>
</table>
<br><br><table STYLE="line-height:130%" cellspacing="0" cellpadding="5" border="1">
    <tr>
        <td align="center"> Fakültemiz öğretim elemanının kısa süreli yurt içi/dışı görevlendirilmesinin yapılması uygun<br><b>görülmüş / görülmemiştir </b></td>
    </tr>
    <tr>
        <td width="66%">Fakülte Yönetim Kurulu Karar No: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Tarih:</td>
        <td width="34%"></td>
    </tr>
    <tr>
        <td width="66%">Dekan &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Tarih: .... / .... / $dateyear <br><br><br>Prof. Dr. Nuri KURUOĞLU&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(İmza)</td>
        <td width="34%" align="center">Teklif edilen ödenek:<br><br>(&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $) &nbsp;&nbsp;&nbsp; (&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; TL)</td>
    </tr>

</table>
<table STYLE="line-height:120%" cellspacing="0" cellpadding="0" border="0">
	<tr>
    	<td><br><br><b>EKLENMESİ GEREKEN BELGELER:</b> (1) Bildiri Özeti, (2) Bildiri Kabul Yazısı, (3) Toplantı ile ilgili bilgiler (Kayıt Ücreti, Tarihleri, vs.) (4) Doktora Öğrencileri için Yeterlilik Belgesi</td>
    </tr>
</table>
EOD;



$pdf->writeHTML($tbl, true, false, false, false, '');



$outputfilename = "Bilimsel_Toplanti_Katilim_".$pid;

// ---------------------------------------------------------

//Close and output PDF document
$pdf->Output($outputfilename, 'D');

//============================================================+
// END OF FILE                                                
//============================================================+

//} else {
	//header('Location: ./index.php?error=2');
//}